package cn.edu.gdut.deepcode.domain.po;

import cn.edu.gdut.deepcode.enums.RoleEnum;
import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import lombok.Data;
import lombok.EqualsAndHashCode;
import lombok.experimental.Accessors;

import java.io.Serializable;
import java.time.LocalDateTime;

/**
 * <p>
 * 用户表
 * </p>
 *
 * @Author: 暮倦
 * @Since: 2025-04-08  21:04
 * @Version: 1.0.0
 */
@Data
@EqualsAndHashCode(callSuper = false)
@Accessors(chain = true)
@TableName("user")
public class User implements Serializable {

    private static final long serialVersionUID = 1L;

    /**
     * 用户id
     */
    @TableId(value = "id", type = IdType.AUTO)
    private Long id;

    /**
     * 账号

     */
    private String username;

    /**
     * 密码
     */
    private String password;
    /**
     * 记住我
     */
    private Boolean re;
    /**
     * 盐
     */
    private String salty;

    /**
     * 用户角色
     */
    private RoleEnum role;


    /**
     * 用户主题
     */
    private String theme="#1890ff";

    /**
     * 逻辑删除
     */
//    private Boolean deleted;

    /**
     * 创建时间
     */
    private LocalDateTime createTime;

    /**
     * 修改时间
     */
    private LocalDateTime updateTime=LocalDateTime.now();


}
